package com.tyk.bookstore.front.comment.model.entity;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;

import java.io.Serial;
import java.io.Serializable;
import java.time.LocalDateTime;

/**
 * @author tyk
 * @description 评论
 */
@Schema(name = "Reply", description = "评论")
@TableName("comment")
@Data
public class CommentDo implements Serializable {
    @Serial
    private static final long serialVersionUID = 1;

    @Schema(description = "ID")
    @TableId("id")
    private Long id;

    @Schema(description = "会员ID")
    @TableField("member_id")
    private Long memberId;

    @Schema(description = "订单ID")
    @TableField("order_id")
    private Long orderId;

    @Schema(description = "订单明细ID")
    @TableField("order_detail_id")
    private Long orderDetailId;

    @Schema(description = "书籍ID")
    @TableField("book_id")
    private Long bookId;

    @Schema(description = "评论内容")
    @TableField("content")
    private String content;

    @Schema(description = "评价等级")
    @TableField("star")
    private Long star;

    @Schema(description = "评论时间")
    @TableField("create_time")
    private LocalDateTime createTime;
}
